package com.echo.code.thread.future.service;

import com.echo.code.thread.future.Future;
import java.util.function.Consumer;
import java.util.function.Function;

/**
 * FutureService Created by baiyap on 2018/9/24.
 */
public interface FutureService<I, O> {

  Future<?> submit(Runnable runnable);

  Future<O> submit(Function<I, O> function, I input);

  Future<O> submit(Function<I, O> function, I input, Consumer<O> callback);
}
